/*
 * @(#)ChangpianJiongXmlGenerator.java		       version: 0.1 
 * Date:2012-2-23
 *
 * Copyright (c) 2011 CFuture09, Institute of Software, 
 * Guangdong Ocean University, Zhanjiang, GuangDong, China.
 * All rights reserved.
 */
package com.sinaapp.msdxblog.tools.xml;

import org.jdom.Attribute;
import org.jdom.Element;

/**
 * @author Geek_Soledad (66704238@51uc.com)
 */
public class ChangpianJiongXmlGenerator extends JiongXmlGenerator{

	@Override
	protected void createChild(Element root) {
		for (int i = 1, length = resSplits.length; i < length; i++) {
			Element content = new Element(CONTENT);
			Attribute id = new Attribute(ID_ATTRIBUTE, i + "");
			content.setAttribute(id);
			content.setText("长篇囧料  \n\n" + resSplits[i].replace("\r", ""));
			root.addContent(content);
		}
	}
	
	public static void main(String[] args) {
		JiongXmlGenerator generator = new ChangpianJiongXmlGenerator();
		generator.generateXmlByPath("E:/androidApk/2012/02/一日一囧/第3期/cp.txt");
	}
}
